package com.longxiao.validator.handler;

import com.longxiao.validator.ValidException;
import com.longxiao.validator.ValidResult;
import com.longxiao.validator.handler.cond.CommCondition;

/**
 * Created by houhongwei on 2017/5/16.
 */
public class ValidNotBlankHander extends CommHandler implements ValidHandler {



    @Override
    public ValidResult doValid(Object value, CommCondition cond) throws ValidException {
        if (isNull(value)) {
            throw new ValidException(getErr(cond));
        }
        return ValidResult.createSucc();
    }
}
